Method, device and medium for enhancing saturation

ABSTRACT

A method, device and medium for enhancing saturation are provided. The method includes: obtaining image feature information of an image; identifying a type of the image according to the image feature information; selecting a saturation enhancement mode corresponding to the type of the image, and enhancing the saturation of the image using the saturation enhancement mode.

CROSS REFERENCE TO RELATED APPLICATION

This application is based upon and claims priority to Chinese PatentApplication Serial No. 201610566361.1, filed with the State IntellectualProperty Office of P. R. China on Jul. 18, 2016, the entire contents ofwhich are incorporated herein by reference.

TECHNICAL FIELD

The present disclosure relates to display technology field, and moreparticularly, to a method, device and medium for enhancing saturation.

BACKGROUND

Saturation is a degree of the brightness of color, also known as thepurity of color. The saturation depends on a proportion of colorfulcomponents and achromatic components in the color. The more the colorfulcomponents are, the larger the saturation is, and the more theachromatic components are, the smaller the saturation is.

There are typical methods for enhancing saturation, which can enhancethe colorfulness of an image. After the methods for enhancing saturationare applied to each image frame displayed in a terminal, it is possibleto enhance display effect of the terminal.

SUMMARY

According to embodiments of the present disclosure, a method forenhancing saturation is provided. The method includes: obtaining imagefeature information of an image; identifying a type of the imageaccording to the image feature information; selecting a saturationenhancement mode corresponding to the type of the image, and enhancingthe saturation of the image using the saturation enhancement mode.

According to embodiments of the present disclosure, a device forenhancing saturation is provided. The device includes: a processor; amemory for storing instructions executable by the processor; in whichthe processor is configured to: obtain image feature information of animage; identify a type of the image according to the image featureinformation; select a saturation enhancement mode corresponding to thetype of the image, and enhance the saturation of the image using thesaturation enhancement mode.

According to embodiments of the present disclosure, there is provided anon-transitory computer-readable storage medium having stored thereininstructions that, when executed by a processor of a device, causes thedevice to perform a method for enhancing saturation, the methodincluding: obtaining image feature information of an image; identifyinga type of the image according to the image feature information;selecting a saturation enhancement mode corresponding to the type of theimage, and enhancing the saturation of the image using the saturationenhancement mode.

It is to be understood that both the foregoing general description andthe following detailed description are exemplary and explanatory onlyand are not restrictive of the present disclosure.

BRIEF DESCRIPTION OF THE DRAWINGS

Accompanying drawings herein are incorporated in and constitute a partof the specification, and illustrate exemplary embodiments in line withthe present disclosure, and serve to explain the principle of thepresent disclosure together with the description.

FIG. 1 is a flow chart showing a method for enhancing saturationaccording to an exemplary embodiment of the present disclosure;

FIG. 2A is a schematic diagram illustrating a natural image and a “colorgradation value-pixel number” histogram of the nature image according toan exemplary embodiment of the present disclosure;

FIG. 2B is a schematic diagram illustrating a UI image and a “colorgradation value-pixel number” histogram of the UI image according to anexemplary embodiment of the present disclosure;

FIG. 2C is a schematic diagram illustrating a UI image and a “colorgradation value-pixel number” histogram of the UI image according toanother exemplary embodiment of the present disclosure;

FIG. 2D is a schematic diagram illustrating a UI image and a “colorgradation value-pixel number” histogram of the UI image according toanother exemplary embodiment of the present disclosure;

FIG. 3 is a flow chart showing a method for enhancing saturationaccording to another exemplary embodiment of the present disclosure;

FIG. 4 is a flow chart showing a method for enhancing saturationaccording to another exemplary embodiment of the present disclosure;

FIG. 5 is a flow chart showing a method for enhancing saturationaccording to another exemplary embodiment of the present disclosure;

FIG. 6 is a schematic diagram illustrating a device for enhancingsaturation according to an exemplary embodiment of the presentdisclosure;

FIG. 7 is a schematic diagram illustrating a device for enhancingsaturation according to another exemplary embodiment of the presentdisclosure.

DETAILED DESCRIPTION

Reference will now be made in detail to exemplary embodiments, examplesof which are illustrated in the accompanying drawings. The followingdescription refers to the accompanying drawings in which the samenumbers in different drawings represent the same or similar elementsunless otherwise represented. The implementations set forth in thefollowing description of exemplary embodiments do not represent allimplementations consistent with the disclosure. Instead, they are merelyexamples of devices and methods consistent with aspects related to thedisclosure as recited in the appended claims.

Typically, a same mode for enhancing saturation is usually used for eachimage frame displayed in a terminal. However, not all images aresuitable for enhancing saturation. For instance, user interface (UI forshort) images are artificially designed, whose original color is veryvivid already. It will reduce beauty degree of the UI images if thesaturation of the UI images is enhanced greatly. Therefore, the presentdisclosure provides exemplary embodiments as follows.

FIG. 1 is a flow chart showing a method for enhancing saturationaccording to an exemplary embodiment of the present disclosure. It isexemplified that the method is applied to a terminal with imageprocessing ability in this embodiment. The method includes followings.

In step 102, image feature information of an image is obtained.

In step 104, a type of the image is identified according to the imagefeature information.

In step 106, a saturation enhancement mode corresponding to the type ofthe image is selected, and the saturation of the image is enhanced usingthe saturation enhancement mode.

In summary, with the method for enhancing saturation provided by theembodiment, by identifying the type of the image according to the imagefeature information, selecting the saturation enhancement modecorresponding to the type of the image, and enhancing the saturation ofthe image using the saturation enhancement mode, it avoids that beautydegree of the UI image may be reduced when each image frame in aterminal is enhanced by the same mode for enhancing saturation. Thus,for each image frame of the terminal, different modes for enhancingsaturation are used for different types, images of each type may get abetter saturation, thus improving display effect of the terminal as awhole.

The type of the image includes: a nature image and a UI image. Thenature image refers to an image produced according to an object thatnaturally exists, or an image generated by simulating an object thatnaturally exists. Common nature images include: an image obtained by acamera, an image frame obtained after decoding a video, an image framein the simulated world which are rendered in real time by a gamerendering engine, etc. The UI image is an image configured forhuman-machine interaction. The UI image is obtained by artificialdesign.

There is different image feature information between the nature imageand the UI image. Taking the image in a color format of Red Green Blue(RGB for short) as an example, an image frame includes pixelsdistributed in X rows and Y columns, that is, X*Y pixels in total. Eachpixel includes three color channels: a red channel R, a green channel Gand a blue channel B. For a pixel, each color channel has a colorgradation value, with a range of [0,255]. For instance, color gradationvalues corresponding to the three color channels of a pixel are (255, 0,0), that is, the color gradation value corresponding to the red channelof the pixel is 255, the color gradation value corresponding to thegreen channel of the pixel is 0, and the color gradation valuecorresponding to the blue channel of the pixel is 0.

It should be noted that, the color gradation value may also be known asa brightness value, a gray value, a channel value or other names. It istaken as an example that the color channel includes three channels inembodiments of the present disclosure, but is not limited to this. Animage may have four or more color channels when the image is in thedifferent color formats.

FIG. 2A shows a natural image and a “color gradation value—the number ofpixels” histogram of the nature image in the three color channels. Thenature image is an outdoor landscape and the histogram shows a pixeldistribution corresponding relationship of the nature image in graphicalform. The pixel distribution corresponding relationship includes acorresponding relationship between a color gradation value and thenumber of pixels having the color gradation value. In the histogram, theabscissa represents the color gradation value, and the ordinaterepresents the pixel number of pixels with the color gradation value inthe image. Ordinarily, a range of the color gradation value is [0, 255].

For instance, for the red channel of the nature image, the number ofpixels corresponding to a color gradation value 0 is 1, the number ofpixels corresponding to a color gradation value 1 is 2, the number ofpixels corresponding to a color gradation value 2 is 2, the number ofpixels corresponding to a color gradation value 3 is 5, . . . , thenumber of pixels corresponding to a color gradation value 67 is 130, . .. , the number of pixels corresponding to a color gradation value 255 is0.

For the green channel of the nature image, the number of pixelscorresponding to a color gradation value 0 is 0, the number of pixelscorresponding to a color gradation value 1 is 0, the number of pixelscorresponding to a color gradation value 2 is 1, the number of pixelscorresponding to a color gradation value 3 is 5, . . . , the number ofpixels corresponding to a color gradation value 102 is 130, . . . , thenumber of pixels corresponding to a color gradation value 255 is 0.

For the blue channel of the nature image, the number of pixelscorresponding to a color gradation value 0 is 0, . . . , the number ofpixels corresponding to a color gradation value 24 is 50, the number ofpixels corresponding to a color gradation value 25 is 52, the number ofpixels corresponding to a color gradation value 26 is 56, . . . , thenumber of pixels corresponding to a color gradation value 255 is 1.

It may be seen from the histogram that a change trend of the number ofpixels respectively corresponding to adjacent color gradation values isa gradual trend, that is, the change trend meets the characteristics ofthe normal distribution, and a sudden change may not happen. The pixelnumber corresponding to each color gradation value has randomness anddecentralization. For instance, a radio of the number of pixelsrespectively corresponding to adjacent color gradation values is0.9907635, which is hard to be divided.

FIG. 2B shows a UI image and a “color gradation value—the number ofpixels” histogram of the UI image in the three color channels. The UIimage includes a variety of color squares that vary according to thegradual change. The pixel number corresponding to each color gradationvalue distributes periodically in the corresponding histogram. A largervalue (the vertical line shown in FIG. 2B) appears for every X colorgradation values.

FIG. 2C shows a UI image and a “color gradation value—the number ofpixels” histogram of the UI image in the three color channels. The UIimage includes color bands that vary according to the gradual change.The pixel number corresponding to each color gradation value distributesperiodically in the corresponding histogram. The number of pixelscorresponding to one part of color gradation values are Y, and thenumber of pixels corresponding to another part of color gradation valuesare 2Y. The two parts of color gradation values alternately andperiodically appear in the abscissa.

FIG. 2D shows a UI image and a “color gradation value—the number ofpixels” histogram of the UI image in the three color channels. The UIimage includes a monochrome background and a flower pattern in thecentral part. As the color gradation value of each pixel in themonochrome background is the same completely, so in the correspondinghistogram, most of the color gradation values are 0 or no larger than50. Only a small part of the color gradation values located at themiddle on the left get a larger value. Relative to the number of pixelscorresponding to the color gradation values of the two adjacent sides ofthe middle on the left, the number of pixels corresponding to the smallpart of the color gradation values show a sudden change feature,suddenly changing from a large value to a small value, in which thesmall value is a value in (0, 50).

It may be seen from FIG. 2B to FIG. 2D that, as the UI image isartificially designed, in which a monochrome background, a combinationdesign of several basic colors, or a pattern designed regularly isusually used, so in the histogram of the UI image, the number of pixelscorresponding to adjacent color gradation values have the sudden changefeature, or regular features may appear in some dimensions for the colorgradation values, the number of pixels corresponding to certain colorgradation values, or color gradation values of some pixels in each colorchannel.

In the following embodiments shown in FIG. 3 to FIG. 5, it is expatiatedin detail how to identify the type of the image in the step 104, inwhich the sudden change feature is used to identify the type inembodiments shown in FIG. 3, the regular feature is used to identify thetype in embodiments shown in FIG. 4, and the sudden change feature andthe regular features are used to identify the type in embodiments shownin FIG. 5.

FIG. 3 is a flow chart showing a method for enhancing saturationaccording to another exemplary embodiment of the present disclosure. Itis exemplified that the method is applied to a terminal having imageprocessing ability in this embodiment. The method includes followings.

In step 301, an image to be displayed in the terminal is obtained.

Images to be displayed are generated frame-by-frame during normaloperation of the terminal. Alternatively, the images are UI imagesgenerated by an operating system of the terminal, UI images generated byan application, nature images played by a video player, nature imagesgenerated by a game program, or photos taken by a camera program etc.

The terminal reads these images as images to be processed.

In step 302, image feature information of the image is obtained, inwhich the image feature information includes a pixel distributioncorresponding relationship of at least one color channel.

In some embodiments, the pixel distribution corresponding relationshipincludes a corresponding relationship between a color gradation valueand the number of pixels having the color gradation value, that is, thecorresponding relationship shown in FIG. 2A to FIG. 2D.

Upon obtaining the image data, the terminal obtains the pixeldistribution corresponding relationship of at least one color channel asthe image feature information of the image by computing the image data.

In some embodiments, the terminal computes a pixel distributioncorresponding relationship of one color channel, the terminal computespixel distribution corresponding relationships of two color channels.Alternatively, the terminal computes pixel distribution correspondingrelationships of all color channels, which shall be determined bycomputing ability, computing speed, real-time requirements or otherfactors.

In step 303, color gradation values are filtered from the pixeldistribution corresponding relationship, and the number of pixelscorresponding to the color gradation values to be filed is less than anoise threshold value.

Since there are some color gradation values and the number of pixelscorresponding to these color gradation values is very small, whichbelongs to meaningless noise, thus, the terminal filters these colorgradation values. The “filter” refers to that these color gradationvalues are removed, or, when the pixel number corresponding to a colorgradation value is less than the noise threshold value, the pixel numbercorresponding to the color gradation value may be set to 0.

The noise threshold value is a numerical threshold, for example, thenoise threshold value is 60. Alternatively, the noise threshold value isa proportional threshold, such as one in ten thousand of total thenumber of pixels.

In step 304, it is detected whether a change trend of the number ofpixels respectively corresponding to adjacent color gradation valuesbelongs to a sudden change trend.

In some embodiments, the sudden change trend includes: there are n₁groups of adjacent color gradation values, in which in each group of then₁ groups of adjacent color gradation values, the difference between thenumber of pixels respectively corresponding to the adjacent colorgradation values is greater than a first threshold value, and n₁ is apositive integer. Alternatively, the sudden change trend includes: thereare n₂ groups of adjacent color gradation values, in which in each ofthe n2 groups of adjacent color gradation values, the ratio between thenumber of pixels respectively corresponding to the adjacent colorgradation values is greater than a second threshold value, and n2 is apositive integer.

The adjacent color gradation values refer to the i^(th) color gradationvalue and the (i+k)^(th) color gradation value, in which i is aninteger, and k is a preset value. For example, if k is 1, the firstcolor gradation value and the second color gradation value are adjacentcolor gradation values, and the 102^(th) color gradation value and the103^(th) color gradation value are adjacent color gradation values. Foranother example, if k is 2, the first color gradation value and thethird color gradation value are adjacent color gradation values, and the99^(th) color gradation value and the 101^(th) color gradation value areadjacent color gradation values. Alternatively, the value of k ispredefined by a developer.

The terminal may detect whether a change trend of the number of pixelscorresponding to n groups of adjacent color gradation values belongs toa sudden change trend. Alternatively, the terminal detects all theadjacent color gradation values, or the terminal detects a group ofadjacent color gradation values every the preset number.

If the change trend does not belong to the sudden change trend, the typeof the image is a nature image, and the method proceeds to the step 305.If the change trend belongs to the sudden change trend, the type of theimage is a UI image, and the method proceeds to the step 306.

For example, when there are 4 groups of adjacent color gradation values,the difference between the number of pixels corresponding to each ofwhich is larger than 80, the type of the image is determined as the UIimage. When differences between the number of pixels corresponding toall of the adjacent color gradation values are less than 80, or thereare only 1, 2 or 3 groups of adjacent color gradation values, thedifference between the number of pixels corresponding to each of whichis larger than 80, the type of the image is determined as the natureimage.

In the step 305, the nature image is determined to be the type, and theimage is enhanced using a first saturation enhancement mode.

In some embodiments, the first saturation enhancement mode refers totransforming each pixel of the image from an original color format to aHue Saturation Value (“HSV”) format, increasing a value of thesaturation component S of each pixel by a preset value A1, and thentransforming each pixel of the enhanced image from the HSV format backto the original color format, thus enhancing the saturation of theimage.

In the step 306, it is determined that the type of the image is the UIimage, and the image is enhanced using a second saturation enhancementmode, or the saturation of the image is kept unchanged.

In some embodiments, the second saturation enhancement mode refers totransforming each pixel of the image from the original color format tothe HSV format, increasing the value of the saturation component S ofeach pixel by a preset value A2, and then transforming each pixel of theenhanced image from the HSV format back to the original color format,thus enhancing the saturation of the image.

In some embodiments, the preset value A2 is less than the preset valueA1, that is, an enhancement level of the saturation for the nature imageis larger than an enhancement level of the saturation for the UI image.

It should be noted that the saturation enhancement modes are not limitedin this embodiment, and the saturation enhancement modes above areexplanatory explanations only.

In summary, with the method for enhancing saturation provided by theembodiment, by detecting whether the change trend of the number ofpixels corresponding to adjacent color gradation values meets the suddenchange feature, if the change trend does not meet the sudden changefeature, identifying the image as the nature image, and enhancing theimage with the first saturation enhancement mode, if the change trendmeets the sudden change feature, identifying the image as the UI image,and enhancing the image with the second saturation enhancement mode orwithout enhancing, it avoids that beauty degree of the UI image may bereduced when each image frame in the terminal is enhanced by the samemode for enhancing saturation. Thus, for each image frame of theterminal, different modes for enhancing saturation are used fordifferent types, images of each type may get a better saturation, thusimproving display effect of the terminal as a whole.

With the method for enhancing saturation provided by the embodiment, byfiltering the noise data in the pixel distribution correspondingrelationship, the interference of the noises data to subsequentdetection process is reduced, thus improving the accuracy of computing.

FIG. 4 is a flow chart showing a method for enhancing saturationaccording to another exemplary embodiment of the present disclosure. Itis exemplified that the method is applied to a terminal having imageprocessing ability in this embodiment. The method includes followings.

In step 401, an image to be displayed in the terminal is obtained.

Images to be displayed are generated frame-by-frame during normaloperation of the terminal. In some embodiments, the images are UI imagesgenerated by an operating system of the terminal, UI images generated byan application, nature images played by a video player, nature imagesgenerated by a game program, or photos taken by a camera program etc.

The terminal reads these images as images to be processed.

In step 402, image feature information of the image is obtained, inwhich the image feature information includes a pixel distributioncorresponding relationship of at least one color channel.

In some embodiments, the pixel distribution corresponding relationshipincludes a corresponding relationship between a color gradation valueand the number of pixels having the color gradation value, that is, thecorresponding relationship shown in FIG. 2A to FIG. 2D.

When obtains the image data, the terminal obtains the pixel distributioncorresponding relationship of at least one color channel as the imagefeature information of the image by computing the image data.

In some embodiments, the terminal computes a pixel distributioncorresponding relationship of one color channel, the terminal computespixel distribution corresponding relationships of two color channels,or, the terminal computes pixel distribution corresponding relationshipsof all color channels, which shall be determined by computing ability,computing speed, real-time requirements or other factors.

In step 403, color gradation values are filtered from the pixeldistribution corresponding relationship, and the number of pixelscorresponding to the color gradation values to be filed is less than anoise threshold value

Since there are some color gradation values and the number of pixelscorresponding to these color gradation values is very small, whichbelongs to meaningless noise, thus, the terminal filters these colorgradation values. The “filter” refers to that these color gradationvalues are removed, or, when the number of pixels corresponding to acolor gradation value is less than the noise threshold value, the numberof pixels corresponding to the color gradation value may be set to 0.

In some embodiments, the noise threshold value is a numerical threshold,for example, the noise threshold value is 60. Alternatively, the noisethreshold value is a proportional threshold, such as one in ten thousandof a total the number of pixels.

In step 404, it is detected whether the color gradation value and thepixel number meet a regular feature.

As the UI image is artificially designed, regular features may appear insome dimensions for the color gradation values, the number of pixelscorresponding to some color gradation values, the correspondingrelationships between color gradation values and the number of pixelscorresponding to the color gradation values, or the color gradationvalues of some pixels in each color channel.

In some embodiments, the regular features of the UI image include butare not limited to at least one of the following features.

There are n3 groups of adjacent color gradation values, in which in eachgroup of the n3 groups of the adjacent color gradation values, the ratiobetween the number of pixels respectively corresponding to the adjacentcolor gradation values is an integer multiple, and n3 is a positiveinteger. Taking FIG. 2B as an example, the number of pixelscorresponding to the ith color gradation value is X, and the number ofpixels corresponding to the (i+k)th adjacent color gradation value is X,then there are the plurality of groups of adjacent color gradationvalues, the ratio of the number of pixels corresponding to which is 1.Taking FIG. 2C as an example, the number of pixels corresponding to theith color gradation value is Y, and the number of pixels correspondingto the (i+k)th adjacent color gradation value is 2Y, then there are theplurality of groups of adjacent color gradation values, the ratio of thenumber of pixels corresponding to which is 2.

Alternatively, there are n4 color gradation values, wherein in each ofthe n4 color gradation values, the number of pixels in each colorchannel is equal, and n4 is a positive integer. Taking FIG. 2B, FIG. 2Cor FIG. 2D as an example, the corresponding the number of pixels in thered channel R, the green channel G and the blue channel B of each colorgradation value are all the same.

Alternatively, there are n5 color gradation values, wherein in each ofthe n5 color gradation values, the ratio between the number of pixels ineach color channel meets a preset proportion, in which the presetproportion is not equal to 1, and n5 is a positive integer. For example,there is a kind of UI image, including a first type of pixels with acolor gradation value (255, 0, 0) and a second type of pixels with acolor gradation value (0, 255, 0). The first type of pixels accounts for⅓ of the total the number of pixels, and the second type of pixelsaccounts for ⅔ of the total the number of pixels. Supposing that for acolor gradation value 0, the number of pixels in the red channel R is200, the number of pixels in the green channel G is 100, and the numberof pixels in the blue channel B is 200, then for the color gradationvalue 0, a proportion between the number of pixels in the red channeland the number of pixels in the green channel is 2, and a proportionbetween the number of pixels in the green channel and the number ofpixels in the blue channel is ½.

Alternatively, there are n₆ pixels, in which each of the n6 pixelscorresponds to a same color gradation value in each color channel, andn6 is a positive integer. For example, for a monochrome image or animage shown in FIG. 2D, there are more than 100 pixels that correspondto exactly the same color gradation value (a, b, c).

The terminal may detect whether the color gradation value and/or thepixel number meets the regular feature. Alternatively, the terminaldetects all the color gradation values and/or all the number of pixels,or the terminal detects a part of the color gradation values and/or apart of the number of pixels.

If the color gradation value and the pixel number do not meet theregular feature, it is determined that the type of the image is thenature image, and the method proceeds to step 405. If the colorgradation value and the pixel number meet the regular feature, it isdetermined that the type of the image is the UI image, and the methodproceeds to step 406.

In the step 405, it is determined that the type of the image is thenature image, and the image is enhanced using a first saturationenhancement mode.

In some embodiments, the first saturation enhancement mode refers totransforming each pixel of the image from an original color format to aHSV format, increasing a value of the saturation component S of eachpixel by a preset value A1, and then transforming each pixel of theenhanced image from the HSV format back to the original color format,thus enhancing the saturation of the image.

In the step 406, it is determined that the type of the image is the UIimage, and the image is enhanced using a second saturation enhancementmode, or the saturation of the image is kept unchanged.

In some embodiments, the second saturation enhancement mode refers totransforming each pixel of the image from the original color format tothe HSV format, increasing the value of the saturation component S ofeach pixel by a preset value A2, and then transforming each pixel of theenhanced image from the HSV format back to the original color format,thus enhancing the saturation of the image.

In some embodiments, the preset value A2 is less than the preset valueA1, that is, an enhancement level of the saturation for the nature imageis larger than an enhancement level of the saturation for the UI image.

It should be noted that the saturation enhancement modes are not limitedin this embodiment, and the saturation enhancement modes above areexplanatory explanations only.

In summary, with the method for enhancing saturation provided by theembodiment, by detecting whether at least one of the color gradationvalue and the pixel number meets the regular feature, if the at leastone of the color gradation value and the pixel number does not meet theregular feature, identifying the image as the nature image, andenhancing the image with the first saturation enhancement mode, if theat least one of the color gradation value and the pixel number meets theregular feature, identifying the image as the UI image, and enhancingthe image with the second saturation enhancement mode or withoutenhancing, it avoids that beauty degree of the UI image may be reducedwhen each image frame in the terminal is enhanced by the same mode forenhancing saturation. Thus, for each image frame of the terminal,different modes for enhancing saturation are used for different types,images of each type may get a better saturation, thus improving displayeffect of the terminal as a whole.

With the method for enhancing saturation provided by the embodiment, byfiltering the noise data in the pixel distribution correspondingrelationship, the interference of the noises data to subsequentdetection process is reduced, thus improving the accuracy of computing.

Embodiments shown in FIG. 5 may be obtained by combining embodimentsshown in FIG. 3 and embodiments shown in FIG. 4.

FIG. 5 is a flow chart showing a method for enhancing saturationaccording to another exemplary embodiment of the present disclosure. Itis exemplified that the method is applied to a terminal having imageprocessing ability in this embodiment. The method includes followings.

In step 501, an image to be displayed in the terminal is obtained.

In step 502, image feature information of the image is obtained, inwhich the image feature information includes a pixel distributioncorresponding relationship of at least one color channel.

In step 503, color gradation values are filtered from the pixeldistribution corresponding relationship, and the number of pixelscorresponding to the color gradation values to be filed is less than anoise threshold value.

In step 504, it is detected whether the color gradation value and thepixel number meet a regular feature.

In some embodiments, the regular features of the UI image include butare not limited to at least one of the features, as detailed in theembodiments of FIG. 4.

If the color gradation value and the pixel number do not meet theregular feature, the method proceeds to step 505. If the color gradationvalue and the pixel number meet the regular feature, the method proceedsto step 507.

At step the 505, it is detected whether a change trend of the number ofpixels corresponding to adjacent color gradation values belongs to asudden change trend.

In some embodiments, the sudden change trend includes: there are n₁groups of adjacent color gradation values, in which in each group of then1 groups of adjacent color gradation values, the difference between thenumber of pixels respectively corresponding to the adjacent colorgradation values is greater than a first threshold value, and n1 is apositive integer.

Alternatively, the sudden change trend includes: there are n₂ groups ofadjacent color gradation values, in which in each of the n2 groups ofadjacent color gradation values, the ratio between the number of pixelsrespectively corresponding to the adjacent color gradation values isgreater than a second threshold value, and n2 is a positive integer.

If the change trend does not belong to the sudden change trend, the typeof the image is a nature image, and the method proceeds to step 506. Ifthe change trend belongs to the sudden change trend, the type of theimage is a UI image, and the method proceeds to step 507.

At the step 506, it is determined that the type of the image is thenature image, and the image is enhanced using a first saturationenhancement mode.

In some embodiments, the first saturation enhancement mode refers totransforming each pixel of the image from an original color format to aHSV format, increasing a value of the saturation component S of eachpixel by a preset value A1, and then transforming each pixel of theenhanced image from the HSV format back to the original color format,thus enhancing the saturation of the image.

At the step 507, it is determined that the type of the image is the UIimage, and the image is enhanced using a second saturation enhancementmode, or the saturation of the image is kept unchanged.

In some embodiments, the second saturation enhancement mode refers totransforming each pixel of the image from the original color format tothe HSV format, increasing the value of the saturation component S ofeach pixel by a preset value A2, and then transforming each pixel of theenhanced image from the HSV format back to the original color format,thus enhancing the saturation of the image.

In some embodiments, the preset value A2 is less than the preset valueA1, that is, an enhancement level of the saturation for the nature imageis larger than an enhancement level of the saturation for the UI image.

It should be noted that the saturation enhancement mode is not limitedin this embodiment, and the saturation enhancement modes above areexplanatory explanations only.

In summary, with the method for enhancing saturation provided by theembodiment, by double detection mechanisms of “the regular feature” and“the sudden change feature”, the type of the image is identified veryaccurately, thus enhancing the nature image with the first saturationenhancement mode and enhancing the UI image with the second saturationenhancement mode or without enhancing. It avoids that beauty degree ofthe UI image may be reduced when each image frame in the terminal isenhanced by the same mode for enhancing saturation. Thus, for each imageof the terminal, different modes for enhancing saturation are used fordifferent types, images of each type may get a better saturation, thusimproving display effect of the terminal as a whole.

With the method for enhancing saturation provided by the embodiment, byfiltering the noise data in the pixel distribution correspondingrelationship, the interference of the noises data to subsequentdetection process is reduced, thus improving the accuracy of computing.

Followings are device embodiments of the present disclosure, which maybe used to execute the method embodiments of the present disclosure.Please refer to the method embodiments of the present disclosure fordetailed description that is not disclosed in the device embodiments ofthe present disclosure.

FIG. 6 is a schematic diagram illustrating a device for enhancingsaturation according to an exemplary embodiment of the presentdisclosure. The device for enhancing saturation may be realized as partor entire of a terminal having image processing ability by software,hardware or combinations thereof. The device includes an obtainingmodule 620, an identifying module 640 and an enhancing module 660.

The obtaining module 620 is configured to obtain image featureinformation of an image.

The identifying module 640 is configured to identify a type of the imageaccording to the image feature information.

The enhancing module 660 is configured to select a saturationenhancement mode corresponding to the type of the image, and to enhancethe saturation of the image using the saturation enhancement mode.

In some embodiments, the image feature information includes a pixeldistribution corresponding relationship of at least one color channel,and the pixel distribution corresponding relationship includes acorresponding relationship between a color gradation value and thenumber of pixels having the color gradation value.

The identifying module 640 is configured to detect whether a changetrend of the number of pixels respectively corresponding to adjacentcolor gradation values belongs to a sudden change trend; if the changetrend does not belong to the sudden change trend, to determine that thetype of the image is a nature image; if the change trend belongs to thesudden change trend, to determine that the type of the image is a userinterface image.

The adjacent color gradation values are two color gradation valueshaving a difference less than a preset value.

In some embodiments, the sudden change trend includes: there are n₁groups of adjacent color gradation values, wherein in each group of then1 groups of adjacent color gradation values, the difference between thenumber of pixels respectively corresponding to the adjacent colorgradation values is greater than a first threshold value, and n1 is apositive integer.

Alternatively, the sudden change trend includes: there are n₂ groups ofadjacent color gradation values, in which in each of the n2 groups ofadjacent color gradation values, the ratio between the number of pixelsrespectively corresponding to the adjacent color gradation values isgreater than a second threshold value, and n2 is a positive integer.

In some embodiments, the image feature information includes a pixeldistribution corresponding relationship of at least one color channel,and the pixel distribution corresponding relationship includes acorresponding relationship between a color gradation value and thenumber of pixels having the color gradation value.

The identifying module 640 is configured to detect whether the colorgradation value and the pixel number meet a regular feature; if thecolor gradation value and the pixel number meet the regular feature, todetermine that the type of the image is a user interface image; if thecolor gradation value and the pixel number do not meet the regularfeature, to determine that the type of the image is a nature image.

In some embodiments, the regular feature is detailed with referenced tothe embodiments of FIG. 4.

In some embodiments, the device further includes a filtering module,configured to filter color gradation values from the pixel distributioncorresponding relationship, and the number of pixels corresponding tothe filter color gradation values to be filed is less than a noisethreshold value

In some embodiments, the enhancing module 660 is configured to enhancethe image with a first saturation enhancement mode, if the type of theimage is the nature image; to enhance the image with a second saturationenhancement mode, or to keep the saturation of the image unchanged, ifthe type of the image is the user interface image.

An enhancement level of the second saturation enhancement mode is lowerthan an enhancement level of the first saturation enhancement mode.

In summary, with the device for enhancing saturation provided by theembodiment, by double detection mechanisms of “the regular feature” and“the sudden change feature”, the type of the image is identified veryaccurately, thus enhancing the nature image with the first saturationenhancement mode and enhancing the UI image with the second saturationenhancement mode or without enhancing. It avoids that beauty degree ofthe UI image may be reduced when each image frame in the terminal isenhanced by the same mode for saturation enhancing. Thus, for each imageof the terminal, different modes for saturation enhancing are used fordifferent types, images of each type may get a better saturation, thusimproving display effect of the terminal as a whole.

With the device for enhancing saturation provided by the embodiment, byfiltering the noise data in the pixel distribution correspondingrelationship, the interference of the noises data to subsequentdetection process is reduced, thus improving the accuracy of computing.

With respect to the device in the above embodiments, specific mannersfor respective modules performing operations have been described indetail in the related method embodiments and detailed descriptionsthereof are omitted herein.

A device for enhancing saturation is provided by an exemplary embodimentof the present disclosure, which may realize the method for enhancingsaturation provided by the present disclosure. The device for enhancingsaturation includes a processor and a memory for storing instructionsexecutable by the processor, in which the processor is configured to:obtain image feature information of an image; identify a type of theimage according to the image feature information; select a saturationenhancement mode corresponding to the type of the image, and enhance thesaturation of the image using the saturation enhancement mode.

FIG. 7 is a schematic diagram illustrating a device for enhancingsaturation according to an exemplary embodiment of the presentdisclosure. For example, the device 700 may be a mobile phone, acomputer, a digital broadcasting terminal, a messaging device, a gameconsole, a tablet device, a medical device, fitness equipment, aPersonal Digital Assistant PDA, and the like.

Referring to FIG. 7, the device 700 may include the following one ormore components: a processing component 702, a memory 704, a powercomponent 706, a multimedia component 708, an audio component 710, anInput/Output (I/O) interface 712, a sensor component 714, and acommunication component 716.

The processing component 702 typically controls overall operations ofthe device 700, such as the operations associated with display,telephone calls, data communications, camera operations, and recordingoperations. The processing component 702 may include one or moreprocessors 718 to execute instructions to perform all or part of thesteps in the above described methods. Moreover, the processing component702 may include one or more modules which facilitate the interactionbetween the processing component 702 and other components. For instance,the processing component 702 may include a multimedia module tofacilitate the interaction between the multimedia component 708 and theprocessing component 702.

The memory 704 is configured to store various types of data to supportthe operation of the device 700. Examples of such data includeinstructions for any applications or methods operated on the device 700,contact data, phonebook data, messages, pictures, video, etc. The memory704 may be implemented using any type of volatile or non-volatile memorydevices, or a combination thereof, such as a static random access memory(SRAM), an electrically erasable programmable read-only memory (EEPROM),an erasable programmable read-only memory (EPROM), a programmableread-only memory (PROM), a read-only memory (ROM), a magnetic memory, aflash memory, a magnetic or optical disk.

The power component 706 provides power to various components of thedevice 700. The power component 706 may include a power managementsystem, one or more power sources, and any other components associatedwith the generation, management, and distribution of power in the device700.

The multimedia component 708 includes a screen providing an outputinterface between the device 700 and the user, and the four corner ofthe screen are rounded. In some embodiments, the screen may include aliquid crystal display (LCD) and a press panel (TP). If the screenincludes the press panel, the screen may be implemented as a pressscreen to receive input signals from the user. The press panel includesone or more press sensors to sense presses, swipes, and other gestureson the press panel. The press sensors may not only sense a boundary of apress or swipe action, but also sense a duration time and a pressureassociated with the press or swipe action. In some embodiments, themultimedia component 708 includes a front camera and/or a rear camera.The front camera and/or the rear camera may receive external multimediadata while the device 700 is in an operation mode, such as aphotographing mode or a video mode. Each of the front camera and therear camera may be a fixed optical lens system or have focus and opticalzoom capability.

The audio component 710 is configured to output and/or input audiosignals. For example, the audio component 710 includes a microphone(MIC) configured to receive an external audio signal when the device 700is in an operation mode, such as a call mode, a recording mode, and avoice recognition mode. The received audio signal may be further storedin the memory 704 or transmitted via the communication component 716. Insome embodiments, the audio component 710 further includes a speaker tooutput audio signals.

The I/O interface 712 provides an interface for the processing component702 and peripheral interface modules, such as a keyboard, a click wheel,buttons, and the like. The buttons may include, but are not limited to,a home button, a volume button, a starting button, and a locking button.

The sensor component 714 includes one or more sensors to provide statusassessments of various aspects of the device 700. For instance, thesensor component 714 may detect an open/closed status of the device 700and relative positioning of components (e.g. the display and the keypadof the device 700. The sensor component 714 may also detect a change inposition of the device 700 or of a component in the device 700, apresence or absence of user contact with the device 700, an orientationor an acceleration/deceleration of the device 700, and a change intemperature of the device 700. The sensor component 714 may include aproximity sensor configured to detect the presence of nearby objectswithout any physical contact. The sensor component 714 may also includea light sensor, such as a CMOS or CCD image sensor, for use in imagingapplications. In some embodiments, the sensor component 714 may alsoinclude an accelerometer sensor, a gyroscope sensor, a magnetic sensor,a pressure sensor, or a temperature sensor.

The communication component 716 is configured to facilitate wired orwireless communication between the device 700 and other devices. Thedevice 700 can access a wireless network based on a communicationstandard, such as WIFI, 2G, or 3G, or a combination thereof. In oneexemplary embodiment, the communication component 716 receives abroadcast signal or broadcast associated information from an externalbroadcast management system via a broadcast channel. In one exemplaryembodiment, the communication component 716 further includes a nearfield communication (NFC) module to facilitate short-rangecommunications. For example, the NFC module may be implemented based ona radio frequency identification (RFID) technology, an infrared dataassociation (IrDA) technology, an ultra-wideband (UWB) technology, aBluetooth (BT) technology, and other technologies.

In exemplary embodiments, the device 700 may be implemented with one ormore application specific integrated circuits (ASICs), digital signalprocessors (DSPs), digital signal processing devices (DSPDs),programmable logic devices (PLDs), field programmable gate arrays(FPGAs), controllers, micro-controllers, microprocessors, or otherelectronic components, for performing the above described methods.

In exemplary embodiments, there is also provided a non-transitorycomputer readable storage medium including instructions, such as thememory 704 including instructions. The instructions may be performed bythe processor 718 of the device 700 so as to realize the method forgenerating information. For example, the non-transitorycomputer-readable storage medium may be a ROM, a RAM, a CD-ROM, amagnetic tape, a floppy disc, an optical data storage device, and thelike.

Other embodiments of the disclosure will be apparent to those skilled inthe art from consideration of the specification and practice of thedisclosure disclosed here. This application is intended to cover anyvariations, uses, or adaptations of the disclosure following the generalprinciples thereof and including such departures from the presentdisclosure as come within known or customary practice in the art. It isintended that the specification and examples be considered as exemplaryonly, with a true scope and spirit of the disclosure being indicated bythe following claims.

It will be appreciated that the present disclosure is not limited to theexact construction that has been described above and illustrated in theaccompanying drawings, and that various modifications and changes can bemade without departing form the scope thereof. It is intended that thescope of the disclosure only be limited by the appended claims.

What is claimed is:
 1. A method for enhancing saturation, the methodcomprising: obtaining image feature information of an image; identifyinga type of the image according to the image feature information; andselecting a saturation enhancement mode corresponding to the type of theimage, and enhancing the saturation of the image using the saturationenhancement mode.
 2. The method according to claim 1, wherein the imagefeature information comprises a pixel distribution correspondingrelationship of at least one color channel, and the pixel distributioncorresponding relationship comprises a corresponding relationshipbetween a color gradation value and the number of pixels having thecolor gradation value; and wherein identifying a type of the imageaccording to the image feature information comprises: detecting whethera change trend of the number of pixels respectively corresponding toadjacent color gradation values belongs to a sudden change trend,wherein the adjacent color gradation values are two color gradationvalues having a difference less than a preset value; determining thatthe type of the image is a nature image if the change trend does notbelong to the sudden change trend; and determining that the type of theimage is a user interface image if the change trend belongs to thesudden change trend.
 3. The method according to claim 2, whereindetecting whether a change trend of the number of pixels respectivelycorresponding to adjacent color gradation values belongs to a suddenchange trend comprises: detecting whether there are n₁ groups of theadjacent color gradation values, wherein in each group of the n₁ groupsof adjacent color gradation values, the difference between the number ofpixels respectively corresponding to the adjacent color gradation valuesis greater than a first threshold value, and n₁ is a positive integer.4. The method according to claim 2, wherein detecting whether a changetrend of the number of pixels respectively corresponding to adjacentcolor gradation values belongs to a sudden change trend comprises:detecting whether there are n₂ groups of the adjacent color gradationvalues, wherein in each of the n₂ groups of adjacent color gradationvalues, the ratio between the number of pixels respectivelycorresponding to the adjacent color gradation values is greater than asecond threshold value, and n₂ is a positive integer.
 5. The methodaccording to claim 1, wherein the image feature information comprises apixel distribution corresponding relationship of at least one colorchannel, and the pixel distribution corresponding relationship comprisesa corresponding relationship between a color gradation value and thenumber of pixels having the color gradation value; and whereinidentifying a type of the image according to the image featureinformation comprises: detecting whether the color gradation value andthe pixel number meets a regular feature; determining that the type ofthe image is a user interface image if the color gradation value and thepixel number meets the regular feature; and determining that the type ofthe image is a nature image if the color gradation value and the pixelnumber do not meet the regular feature.
 6. The method according to claim5, wherein detecting whether the color gradation value and the pixelnumber meet the regular feature comprises any one of: detecting whetherthere are n₃ groups of the adjacent color gradation values, wherein ineach group of the n₃ groups of the adjacent color gradation values, theratio between the number of pixels respectively corresponding to theadjacent color gradation values is an integer multiple, and n₃ is apositive integer; detecting whether there are n₄ color gradation values,wherein in each of the n₄ color gradation values, the number of pixelsin each color channel is equal, and n₄ is a positive integer; detectingwhether there are n₅ color gradation values, wherein in each of the n₅color gradation values, the ratio between the number of pixels in eachcolor channel meets a preset proportion, in which the preset proportionis not equal to 1, and n₅ is a positive integer; detecting whether thereare n₆ pixels, wherein each of the n₆ pixels corresponds to a same colorgradation value in each color channel, and n₆ is a positive integer. 7.The method according to claim 2, further comprising: filtering colorgradation values from the pixel distribution corresponding relationship,wherein the number of pixels corresponding to the color gradation valuesis less than a noise threshold value.
 8. The method according to claim1, wherein selecting a saturation enhancement mode corresponding to thetype of the image and enhancing the saturation of the image using thesaturation enhancement mode comprises: enhancing the image using a firstsaturation enhancement mode if the type of the image is the natureimage; enhancing the image using a second saturation enhancement mode ifthe type of the image is the user interface image, wherein anenhancement level of the second saturation enhancement mode is lowerthan an enhancement level of the first saturation enhancement mode.
 9. Adevice for enhancing saturation, the device comprising: a processor; amemory for storing instructions executable by the processor; wherein theprocessor is configured to: obtain image feature information of animage; identify a type of the image according to the image featureinformation; and select a saturation enhancement mode corresponding tothe type of the image, and enhance the saturation of the image using thesaturation enhancement mode.
 10. The device according to claim 9,wherein the image feature information comprises a pixel distributioncorresponding relationship of at least one color channel, and the pixeldistribution corresponding relationship comprises a correspondingrelationship between a color gradation value and the number of pixelshaving the color gradation value; and wherein the processor isconfigured to identify a type of the image according to the imagefeature information by acts of: detecting whether a change trend of thenumber of pixels respectively corresponding to adjacent color gradationvalues belongs to a sudden change trend, wherein the adjacent colorgradation values are two color gradation values having a difference lessthan a preset value; determining that the type of the image is a natureimage if the change trend does not belong to the sudden change trend;and determining that the type of the image is a user interface image ifthe change trend belongs to the sudden change trend.
 11. The deviceaccording to claim 10, wherein detecting whether a change trend of thenumber of pixels respectively corresponding to adjacent color gradationvalues belongs to a sudden change trend comprises: detecting whetherthere are n₁ groups of the adjacent color gradation values, wherein ineach group of the n₁ groups of adjacent color gradation values, thedifference between the number of pixels respectively corresponding tothe adjacent color gradation values is greater than a first thresholdvalue, and n₁ is a positive integer.
 12. The device according to claim10, wherein detecting whether a change trend of the number of pixelsrespectively corresponding to adjacent color gradation values belongs toa sudden change trend comprises: detecting whether there are n₂ groupsof the adjacent color gradation values, wherein in each of the n₂ groupsof adjacent color gradation values, the ratio between the number ofpixels respectively corresponding to the adjacent color gradation valuesis greater than a second threshold value, and n₂ is a positive integer.13. The device according to claim 9, wherein the image featureinformation comprises a pixel distribution corresponding relationship ofat least one color channel, and the pixel distribution correspondingrelationship comprises a corresponding relationship between a colorgradation value and the number of pixels having the color gradationvalue; and wherein the processor is configured to identify a type of theimage according to the image feature information by acts of: detectingwhether the color gradation value and the pixel number meet a regularfeature; determining that the type of the image is a user interfaceimage if the color gradation value and the pixel number meet the regularfeature; determining that the type of the image is a nature image if thecolor gradation value and the pixel number does not meet the regularfeature.
 14. The device according to claim 13, wherein detecting whetherthe color gradation value and the pixel number meet the regular featurecomprises any one of: detecting whether there are n₃ groups of theadjacent color gradation values, wherein in each group of the n₃ groupsof the adjacent color gradation values, the ratio between the number ofpixels respectively corresponding to the adjacent color gradation valuesis an integer multiple, and n₃ is a positive integer; detecting whetherthere are n₄ color gradation values, wherein in each of the n₄ colorgradation values, the number of pixels in each color channel is equal,and n₄ is a positive integer; detecting whether there are n₅ colorgradation values, wherein in each of the n₅ color gradation values, theratio between the number of pixels in each color channel meets a presetproportion, in which the preset proportion is not equal to 1, and n₅ isa positive integer; detecting whether there are n₆ pixels, wherein eachof the n₆ pixels corresponds to a same color gradation value in eachcolor channel, and n₆ is a positive integer.
 15. The device according toclaim 10, wherein the processor is further configured to: filter colorgradation values from the pixel distribution corresponding relationship,wherein the number of pixels corresponding to the color gradation valuesis less than a noise threshold value.
 16. The device according to claim9, wherein the processor is configured to select a saturationenhancement mode corresponding to the type of the image and to enhancethe saturation of the image using the saturation enhancement mode byacts of: enhancing the image with a first saturation enhancement mode ifthe type of the image is the nature image; enhancing the image with asecond saturation enhancement mode if the type of the image is the userinterface image, wherein an enhancement level of the second saturationenhancement mode is lower than an enhancement level of the firstsaturation enhancement mode.
 17. A non-transitory computer-readablestorage medium having stored therein instructions that, when executed bya processor of a device, causes the device to perform a method forenhancing saturation, the method comprising: obtaining image featureinformation of an image; identifying a type of the image according tothe image feature information; and selecting a saturation enhancementmode corresponding to the type of the image, and enhancing thesaturation of the image using the saturation enhancement mode.
 18. Thenon-transitory computer-readable storage medium according to claim 17,wherein the image feature information comprises a pixel distributioncorresponding relationship of at least one color channel, and the pixeldistribution corresponding relationship comprises a correspondingrelationship between a color gradation value and the number of pixelshaving the color gradation value; and wherein identifying a type of theimage according to the image feature information comprises: detectingwhether a change trend of the number of pixels respectivelycorresponding to adjacent color gradation values belongs to a suddenchange trend, wherein the adjacent color gradation values are two colorgradation values having a difference less than a preset value;determining that the type of the image is a nature image if the changetrend does not belong to the sudden change trend; determining that thetype of the image is a user interface image if the change trend belongsto the sudden change trend.
 19. The non-transitory computer-readablestorage medium according to claim 18, wherein detecting whether a changetrend of the number of pixels respectively corresponding to adjacentcolor gradation values belongs to a sudden change trend comprises:detecting whether there are n₁ groups of the adjacent color gradationvalues, wherein in each group of the n₁ groups of adjacent colorgradation values, the difference between the number of pixelsrespectively corresponding to the adjacent color gradation values isgreater than a first threshold value, and n₁ is a positive integer. 20.The non-transitory computer-readable storage medium according to claim18, wherein detecting whether a change trend of the number of pixelsrespectively corresponding to adjacent color gradation values belongs toa sudden change trend comprises: detecting whether there are n₂ groupsof the adjacent color gradation values, wherein in each of the n₂ groupsof adjacent color gradation values, the ratio between the number ofpixels respectively corresponding to the adjacent color gradation valuesis greater than a second threshold value, and n₂ is a positive integer.